function viewAZ(){
	userPostId = getParameterByName("userPostId", getLocationUrl(event) );
	thisWorkConType = getParameterByName("workConType", getLocationUrl(event) );
	//如果日志类型不是1，则回到我的日志页面
	if(thisWorkConType=="1"){
		goTo2(rootPath+"/jsp/weixin/workConViewList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId+"&viewType=AZ",false);
	}else{
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	}
	
}

function viewAF(){
	userPostId = getParameterByName("userPostId", getLocationUrl(event) );
	thisWorkConType = getParameterByName("workConType", getLocationUrl(event) );
	//如果日志类型不是1，则回到我的日志页面
	if(thisWorkConType=="1"){
		goTo2(rootPath+"/jsp/weixin/workConViewList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId+"&viewType=AF",false);
	}else{
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	}
}

function viewBZ(){
	userPostId = getParameterByName("userPostId", getLocationUrl(event) );
	thisWorkConType = getParameterByName("workConType", getLocationUrl(event) );
	//如果日志类型不是4，则回到我的日志页面
	if(thisWorkConType=="4"){
		goTo2(rootPath+"/jsp/weixin/workConViewList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId+"&viewType=BZ",false);
	}else{
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	}
}

function viewBF(){
	userPostId = getParameterByName("userPostId", getLocationUrl(event) );
	thisWorkConType = getParameterByName("workConType", getLocationUrl(event) );
	//如果日志类型不是4，则回到我的日志页面
	if(thisWorkConType=="4"){
		goTo2(rootPath+"/jsp/weixin/workConViewList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId+"&viewType=BF",false);
	}else{
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	}
}

$( document ).on( "pagecreate", "#workConSelectList", function( event ) {
	userPostId = getParameterByName("userPostId", getLocationUrl(event) );
	thisWorkConType = getParameterByName("workConType", getLocationUrl(event) );
	$("#workConViewList_myWorkLog").on('click', function () {
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	});
	if(thisWorkConType=="1"){
		$("#viewBZ").hide();
		$("#viewBF").hide();
	}else if(thisWorkConType=="4"){
		$("#viewAZ").hide();
		$("#viewAF").hide();
	}else{
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	}
	
});


$( document ).on( "pageshow", "#workConSelectList", function( event ) {
	userPostId = getParameterByName("userPostId", getLocationUrl(event) );
	thisWorkConType = getParameterByName("workConType", getLocationUrl(event) );
	$("#workConViewList_myWorkLog").on('click', function () {
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	});
	if(thisWorkConType=="1"){
		$("#viewBZdiv").hide();
		$("#viewBFdiv").hide();
	}else if(thisWorkConType=="4"){
		$("#viewAZdiv").hide();
		$("#viewAFdiv").hide();
	}else{
		goTo2(rootPath+"/jsp/weixin/workConList.jsp?access_token="+access_token+"&workConType="+thisWorkConType+"&userPostId="+userPostId,false);
	}
});